<div class="form-group">
  <div class="col-lg-8">
    <?php if(count($attrs)>1){?>
    <?php for($i=0;$i<count($attrs)/2;$i++){?>
    <div class="form-group rule">
      <div class="col-lg-2 col-lg-offset-3">
        <input type="text" class="form-control tou" name="tou[]" value="{{$attrs['tou_'.$i]}}" data-rule-number="true" data-rule-required="true"/>
      </div>
      <div class="col-lg-2 form-control-static">元，送</div>
      <div class="col-lg-2">
        <input type="text" class="form-control son" name="son[]" value="{{$attrs['son_'.$i]}}" data-rule-number="true" data-rule-required="true"/>
      </div>
      <div class="col-lg-2">
        <button type="button" class="btn btn-sm btn-danger" onclick="delGroup(this)"><i class="fa fa-trash-o"></i>&nbsp;&nbsp;删除</button>
      </div>
    </div>
    <?php }}else{?>
    <div class="form-group rule">
      <div class="col-lg-2 col-lg-offset-3">
        <input type="text" class="form-control tou" name="tou[]" data-rule-number="true" data-rule-required="true"/>
      </div>
      <div class="col-lg-2 form-control-static">元，送</div>
      <div class="col-lg-2">
        <input type="text" class="form-control son" name="son[]" data-rule-number="true" data-rule-required="true"/>
      </div>
      <div class="col-lg-2">
        <button type="button" class="btn btn-sm btn-danger" onclick="delGroup(this)"><i class="fa fa-trash-o"></i>&nbsp;&nbsp;删除</button>
      </div>
    </div>
    <?php }?>
  </div>
  <div class="col-lg-2 option">
    <button type="button" class="btn btn-sm btn-default" onclick="addGroup()" id="add-group"><i class="fa fa-plus"></i>&nbsp;&nbsp;增加</button>
    <label class="i-checks"><input type="checkbox" name="auto" value="1" {{$auto?'checked':''}} onclick="chckGroup()" id="is_auto"><i></i>是否递增</label>
  </div>
</div>